<#include "/admin/public.html">
<div style="padding:5px;">
	<table class="layui-table" lay-skin="line" id="example-basic">
	  <thead>
		<tr>
		  <th>用户名</th>
		  <th>真实姓名</th>
		  <th>手机号</th>
		  <th>邮箱</th>
		  <th>文件名称</th>
		  <th>下载时间</th>
		</tr> 
	  </thead>
	  <tbody>
		<#if downsList?? && downsList??>
		<#list downsList.content as list>
		<tr>
		  <td class="add">${list.name!''}</td>
		  <td>${list.username!''}</td>
		  <td>${list.telephone!''}</td>
		  <td>${list.email!''}</td>
		  <td>${list.filename!''}</td>
		  <td>${list.downtime!?string("yyyy-MM-dd")}</td>
		</tr>
		</#list>
		</#if>
	  </tbody>
	</table>
</div> 	   
<div style="padding:5px;">
	<div class="col-lg-12" id="page1" style="text-align:center;"></div>
</div>
<script>
/* var list= [];
<#list downsList.content as list>
	list.push({"id":"${list.id!''}","name":"${list.name!''}"});
</#list>
console.log(list); */

layui.use(['laypage', 'layer'], function(){
   var laypage = layui.laypage
   ,layer = layui.layer;
   laypage({
		cont: 'page1'
		,pages: <#if downsList??>${downsList.totalPages}<#else>0</#if> //总页数
		,curr:<#if downsList??>${downsList.number+1}<#else>0</#if>
		,groups: 5 //连续显示分页数
		,jump:function(data , first){
			if(!first){
				location.href = "/admin/microcase/list.html?p="+data.curr ;
			}
		}
   });
  
});
</script>